package testshop.entity;

public class Goods {

    private int gid;
    private  String gname;
    private  Double gprice;
    private  int gnum;


    //构造


    public Goods(int gid, String gname, Double gprice, int gnum) {
        this.gid = gid;
        this.gname = gname;
        this.gprice = gprice;
        this.gnum = gnum;
    }

    public Goods(String gname, Double gprice, int gnum) {

        this.gname = gname;
        this.gprice = gprice;
        this.gnum = gnum;
    }

    public Goods(int gid ,Double gprice){
        this.gid = gid;
        this.gprice = gprice;
    }

    public Goods(int gid ,int gnum){
        this.gid = gid;
        this.gnum = gnum;
    }
    public Goods(int gid ,String gname){
        this.gid = gid;
        this.gname = gname;
    }




    //SET
    public void setGid(int gid) {
        this.gid = gid;
    }

    public void setGname(String gname) {
        this.gname = gname;
    }

    public void setGprice(Double gprice) {
        this.gprice = gprice;
    }

    public void setGnum(int gnum) {
        this.gnum = gnum;
    }


    //GET

    public int getGid() {
        return gid;
    }

    public String getGname() {
        return gname;
    }

    public Double getGprice() {
        return gprice;
    }

    public int getGnum() {
        return gnum;
    }
}
